import logging
from logging import handlers
import os

bash_path = "logs/"

if not os.path.isdir(bash_path):
    os.mkdir(bash_path)

logger_time = logging.getLogger("time")
logger_time.setLevel(logging.INFO)
log_path_time = bash_path + "time.log"
handler_time = logging.FileHandler(log_path_time)
handler_time.setFormatter(logging.Formatter('%(asctime)s - %(filename)s[line:%(lineno)d] - %(levelname)s: %(message)s'))
logger_time.addHandler(handler_time)

logger_error = logging.getLogger("error")
logger_error.setLevel(logging.ERROR)
log_path_error = bash_path + "error.log"
handler_error = logging.FileHandler(log_path_error)
handler_error.setFormatter(logging.Formatter('%(asctime)s - %(filename)s[line:%(lineno)d] - %(levelname)s: %(message)s'))
logger_error.addHandler(handler_error)


